<?php

require_once 'portal.php';

output(get_all_params($input), $debug);

function get_all_params()
{
  $sql = "SELECT * FROM `pims_config_params`";
  $res = exec_sql($sql);
  $params = array();
  if ($res) {
    foreach ($res as $param) {
      // array_push($params, array($param['name'] => json_decode($param['value'])));
      $params[$param['name']] = json_decode($param['value']);
    }
  }
  return $params;
}
